<template>
  <div class="child">
    <h3>子组件</h3>
		<h4>父给的车：{{che}}</h4>
		<h4>我的玩具：{{toy}}</h4>
		<button @click="sendToy(toy)">点我把玩具给父亲</button>
  </div>
</template>

<script>
	export default {
		name: 'Child',
		props:['che','sendToy'],
		data() {
			return {
				toy:'奥特曼'
			}
		},
	}
</script>

<style lang="less" scoped>
	.child{
		margin-top: 50px;
		background-color: skyblue;
		padding: 10px;
		box-shadow: 0 0 10px black;
		border-radius: 10px;
	}
</style>
